package com.huak.boot;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.WebApplicationType;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.ConfigurableApplicationContext;

import java.util.HashSet;
import java.util.Set;

//@SpringBootApplication
public class Application {

	public static void main(String[] args) {

		Set<String> sources=new HashSet<>();
		sources.add(MyConfiguration.class.getName());

		SpringApplication springApplication=new SpringApplication();
		springApplication.setSources(sources);
		springApplication.setWebApplicationType(WebApplicationType.NONE);
		ConfigurableApplicationContext context=springApplication.run(args);
		System.out.println(context.getBean(MyConfiguration.class));
	}


	@SpringBootApplication
	public  static class MyConfiguration{

	}

}
